<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../../js/vue.js"></script>
</head>

<body>
    <div id="app">
        {{result}}
        <span v-if="result>=90">优秀</span>
        <span v-else-if="result>=80">良好</span>
        <span v-else-if="result>=70">一般</span>
        <span v-else-if="result>=60">及格</span>
        <span v-else>不及格</span>
    </div>
</body>
<script>
    new Vue({
        el: "#app",
        data: {
            result: Math.round(Math.random() * 100),
        }
    })
</script>

</html>